using System;
using System.Collections.Generic;
using System.Text;
using AF_ORM.CORE;
using System.Data;
using System.Configuration;
using Bussiness.Config;     
using Bussiness.Entity;
namespace Bussiness.ManagerBase
{
                

     public abstract class PT_Service_ModelManagerBase
    {
        public PT_Service_ModelManagerBase()
        {
            Adapter.ConnectionString =  ConnectionConfig.ConnectionString;            
        }
                    
 
        /// <summary>
        /// Them moi du lieu
        /// </summary>
        /// <returns>PT_Service_ModelEntity</returns>
        public PT_Service_ModelEntity Insert(PT_Service_ModelEntity obj)
        { 
            return (PT_Service_ModelEntity) Adapter.Insert(obj);             
        }
 
 
        /// <summary>
        /// Update du lieu theo khoa chinh cua object
        /// </summary>
        /// <returns>PT_Service_ModelEntity</returns>
        public PT_Service_ModelEntity Update(PT_Service_ModelEntity obj)
        { 
            return (PT_Service_ModelEntity)Adapter.Update(obj);             
        }

 
        public PT_Service_ModelEntity Delete(PT_Service_ModelEntity obj)
        { 
            return (PT_Service_ModelEntity)Adapter.Delete(obj);             
        }
 
        /// <summary>
        /// Xoa cac dong du lieu thoa dieu kien AgentPrice duoc set trong object
        /// </summary>
        /// <returns>PT_Service_ModelEntity</returns>
        public PT_Service_ModelEntity DeleteByAgentPrice (PT_Service_ModelEntity obj)
        { 
            return (PT_Service_ModelEntity)Adapter.DeleteByField(obj,"AgentPrice");
        }

        /// <summary>
        /// Xoa cac dong du lieu thoa dieu kien AgentPrice 
        /// </summary>
        /// <returns>PT_Service_ModelEntity</returns>
        public PT_Service_ModelEntity DeleteByAgentPrice (double AgentPrice )
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.AgentPrice = AgentPrice;  
            return (PT_Service_ModelEntity)Adapter.DeleteByField(obj,"AgentPrice");
        }

        /// <summary>
        /// Xoa cac dong du lieu thoa dieu kien Id duoc set trong object
        /// </summary>
        /// <returns>PT_Service_ModelEntity</returns>
        public PT_Service_ModelEntity DeleteById (PT_Service_ModelEntity obj)
        { 
            return (PT_Service_ModelEntity)Adapter.DeleteByField(obj,"Id");
        }

        /// <summary>
        /// Xoa cac dong du lieu thoa dieu kien Id 
        /// </summary>
        /// <returns>PT_Service_ModelEntity</returns>
        public PT_Service_ModelEntity DeleteById (int Id )
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.Id = Id;  
            return (PT_Service_ModelEntity)Adapter.DeleteByField(obj,"Id");
        }

        /// <summary>
        /// Xoa cac dong du lieu thoa dieu kien ModelCode duoc set trong object
        /// </summary>
        /// <returns>PT_Service_ModelEntity</returns>
        public PT_Service_ModelEntity DeleteByModelCode (PT_Service_ModelEntity obj)
        { 
            return (PT_Service_ModelEntity)Adapter.DeleteByField(obj,"ModelCode");
        }

        /// <summary>
        /// Xoa cac dong du lieu thoa dieu kien ModelCode 
        /// </summary>
        /// <returns>PT_Service_ModelEntity</returns>
        public PT_Service_ModelEntity DeleteByModelCode (string ModelCode )
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.ModelCode = ModelCode;  
            return (PT_Service_ModelEntity)Adapter.DeleteByField(obj,"ModelCode");
        }

        /// <summary>
        /// Xoa cac dong du lieu thoa dieu kien Price duoc set trong object
        /// </summary>
        /// <returns>PT_Service_ModelEntity</returns>
        public PT_Service_ModelEntity DeleteByPrice (PT_Service_ModelEntity obj)
        { 
            return (PT_Service_ModelEntity)Adapter.DeleteByField(obj,"Price");
        }

        /// <summary>
        /// Xoa cac dong du lieu thoa dieu kien Price 
        /// </summary>
        /// <returns>PT_Service_ModelEntity</returns>
        public PT_Service_ModelEntity DeleteByPrice (double Price )
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.Price = Price;  
            return (PT_Service_ModelEntity)Adapter.DeleteByField(obj,"Price");
        }

        /// <summary>
        /// Xoa cac dong du lieu thoa dieu kien ServiceCode duoc set trong object
        /// </summary>
        /// <returns>PT_Service_ModelEntity</returns>
        public PT_Service_ModelEntity DeleteByServiceCode (PT_Service_ModelEntity obj)
        { 
            return (PT_Service_ModelEntity)Adapter.DeleteByField(obj,"ServiceCode");
        }

        /// <summary>
        /// Xoa cac dong du lieu thoa dieu kien ServiceCode 
        /// </summary>
        /// <returns>PT_Service_ModelEntity</returns>
        public PT_Service_ModelEntity DeleteByServiceCode (string ServiceCode )
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.ServiceCode = ServiceCode;  
            return (PT_Service_ModelEntity)Adapter.DeleteByField(obj,"ServiceCode");
        }

 
        /// <summary>
        /// Lay du lieu theo khoa chinh object
        /// </summary>
        /// <returns></returns>
        public PT_Service_ModelEntity Select(PT_Service_ModelEntity obj)
        { 
            return (PT_Service_ModelEntity) Adapter.Select(obj);             
        }
 
 
        /// <summary>
        /// Lay du lieu theo cac dieu kien duoc set trong object
        /// </summary>
        /// <returns></returns>
        public DataTable SelectWithCondition(PT_Service_ModelEntity obj)
        { 
            return  Adapter.SelectWithCondition(obj);             
        }
 
 
        /// <summary>
        /// Lay du lieu theo cac dieu kien duoc set trong object
        /// </summary>
        /// <returns></returns>
        public DataTable SelectWithCondition(PT_Service_ModelEntity obj,SelectOptions option)
        {             
            return  Adapter.SelectWithCondition(obj,option);             
        }
 
 
        /// <summary>
        /// Lay tat ca cac du lieu trong table
        /// </summary>
        /// <returns></returns>
        public DataTable SelectAll()
        { 
            return Adapter.SelectAll(new PT_Service_ModelEntity());             
        }
 
 
        /// <summary>
        /// Lay tat ca cac du lieu trong table
        /// </summary>
        /// <returns></returns>
        public DataTable SelectAll(SelectOptions option)
        { 
            return Adapter.SelectAll(new PT_Service_ModelEntity(),option);             
        }
 
 
        /// <summary>
        /// Lay tat ca cac du lieu trong table
        /// </summary>
        /// <returns></returns>
        public List<PT_Service_ModelEntity> SelectAllLST()
        { 
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList(Adapter.SelectAll(new PT_Service_ModelEntity()),new PT_Service_ModelEntity());           
        }
 
 
        /// <summary>
        /// Lay tat ca cac du lieu trong table
        /// </summary>
        /// <returns></returns>
        public List<PT_Service_ModelEntity> SelectAllLST(SelectOptions option)
        { 
            return (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList(Adapter.SelectAll(new PT_Service_ModelEntity(),option),new PT_Service_ModelEntity());             
        }
 

        /// <summary>
        /// Lay du lieu theo cac dieu kien AgentPrice duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectByAgentPrice (PT_Service_ModelEntity obj)
        { 
            return Adapter.SelectByField(obj,"AgentPrice");
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien AgentPrice duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectByAgentPrice (PT_Service_ModelEntity obj,SelectOptions option)
        { 
            return Adapter.SelectByField(obj,"AgentPrice",option);
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien AgentPrice duoc set trong object
        /// </summary>
        /// <returns>List<PT_Service_ModelEntity></returns>
        public List<PT_Service_ModelEntity> SelectByAgentPriceLST (PT_Service_ModelEntity obj)
        { 
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList(Adapter.SelectByField(obj,"AgentPrice"),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien AgentPrice duoc set trong object
        /// </summary>
        /// <returns>List<PT_Service_ModelEntity></returns>
        public List<PT_Service_ModelEntity> SelectByAgentPriceLST (PT_Service_ModelEntity obj,SelectOptions option)
        { 
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList( Adapter.SelectByField(obj,"AgentPrice",option),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien AgentPrice 
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectByAgentPrice (double AgentPrice )
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.AgentPrice = AgentPrice;  
            return Adapter.SelectByField(obj,"AgentPrice");
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien AgentPrice duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectByAgentPrice (double AgentPrice, SelectOptions option)
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.AgentPrice = AgentPrice;  
            return Adapter.SelectByField(obj,"AgentPrice",option);
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien AgentPrice 
        /// </summary>
        /// <returns>DataTable</returns>
        public List<PT_Service_ModelEntity> SelectByAgentPriceLST (double AgentPrice )
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.AgentPrice = AgentPrice;  
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList(Adapter.SelectByField(obj,"AgentPrice"),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien AgentPrice duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public List<PT_Service_ModelEntity> SelectByAgentPriceLST (double AgentPrice, SelectOptions option)
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.AgentPrice = AgentPrice;  
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList(Adapter.SelectByField(obj,"AgentPrice",option),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien Id duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectById (PT_Service_ModelEntity obj)
        { 
            return Adapter.SelectByField(obj,"Id");
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien Id duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectById (PT_Service_ModelEntity obj,SelectOptions option)
        { 
            return Adapter.SelectByField(obj,"Id",option);
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien Id duoc set trong object
        /// </summary>
        /// <returns>List<PT_Service_ModelEntity></returns>
        public List<PT_Service_ModelEntity> SelectByIdLST (PT_Service_ModelEntity obj)
        { 
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList(Adapter.SelectByField(obj,"Id"),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien Id duoc set trong object
        /// </summary>
        /// <returns>List<PT_Service_ModelEntity></returns>
        public List<PT_Service_ModelEntity> SelectByIdLST (PT_Service_ModelEntity obj,SelectOptions option)
        { 
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList( Adapter.SelectByField(obj,"Id",option),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien Id 
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectById (int Id )
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.Id = Id;  
            return Adapter.SelectByField(obj,"Id");
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien Id duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectById (int Id, SelectOptions option)
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.Id = Id;  
            return Adapter.SelectByField(obj,"Id",option);
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien Id 
        /// </summary>
        /// <returns>DataTable</returns>
        public List<PT_Service_ModelEntity> SelectByIdLST (int Id )
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.Id = Id;  
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList(Adapter.SelectByField(obj,"Id"),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien Id duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public List<PT_Service_ModelEntity> SelectByIdLST (int Id, SelectOptions option)
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.Id = Id;  
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList(Adapter.SelectByField(obj,"Id",option),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien ModelCode duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectByModelCode (PT_Service_ModelEntity obj)
        { 
            return Adapter.SelectByField(obj,"ModelCode");
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien ModelCode duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectByModelCode (PT_Service_ModelEntity obj,SelectOptions option)
        { 
            return Adapter.SelectByField(obj,"ModelCode",option);
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien ModelCode duoc set trong object
        /// </summary>
        /// <returns>List<PT_Service_ModelEntity></returns>
        public List<PT_Service_ModelEntity> SelectByModelCodeLST (PT_Service_ModelEntity obj)
        { 
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList(Adapter.SelectByField(obj,"ModelCode"),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien ModelCode duoc set trong object
        /// </summary>
        /// <returns>List<PT_Service_ModelEntity></returns>
        public List<PT_Service_ModelEntity> SelectByModelCodeLST (PT_Service_ModelEntity obj,SelectOptions option)
        { 
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList( Adapter.SelectByField(obj,"ModelCode",option),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien ModelCode 
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectByModelCode (string ModelCode )
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.ModelCode = ModelCode;  
            return Adapter.SelectByField(obj,"ModelCode");
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien ModelCode duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectByModelCode (string ModelCode, SelectOptions option)
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.ModelCode = ModelCode;  
            return Adapter.SelectByField(obj,"ModelCode",option);
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien ModelCode 
        /// </summary>
        /// <returns>DataTable</returns>
        public List<PT_Service_ModelEntity> SelectByModelCodeLST (string ModelCode )
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.ModelCode = ModelCode;  
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList(Adapter.SelectByField(obj,"ModelCode"),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien ModelCode duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public List<PT_Service_ModelEntity> SelectByModelCodeLST (string ModelCode, SelectOptions option)
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.ModelCode = ModelCode;  
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList(Adapter.SelectByField(obj,"ModelCode",option),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien Price duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectByPrice (PT_Service_ModelEntity obj)
        { 
            return Adapter.SelectByField(obj,"Price");
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien Price duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectByPrice (PT_Service_ModelEntity obj,SelectOptions option)
        { 
            return Adapter.SelectByField(obj,"Price",option);
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien Price duoc set trong object
        /// </summary>
        /// <returns>List<PT_Service_ModelEntity></returns>
        public List<PT_Service_ModelEntity> SelectByPriceLST (PT_Service_ModelEntity obj)
        { 
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList(Adapter.SelectByField(obj,"Price"),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien Price duoc set trong object
        /// </summary>
        /// <returns>List<PT_Service_ModelEntity></returns>
        public List<PT_Service_ModelEntity> SelectByPriceLST (PT_Service_ModelEntity obj,SelectOptions option)
        { 
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList( Adapter.SelectByField(obj,"Price",option),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien Price 
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectByPrice (double Price )
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.Price = Price;  
            return Adapter.SelectByField(obj,"Price");
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien Price duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectByPrice (double Price, SelectOptions option)
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.Price = Price;  
            return Adapter.SelectByField(obj,"Price",option);
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien Price 
        /// </summary>
        /// <returns>DataTable</returns>
        public List<PT_Service_ModelEntity> SelectByPriceLST (double Price )
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.Price = Price;  
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList(Adapter.SelectByField(obj,"Price"),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien Price duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public List<PT_Service_ModelEntity> SelectByPriceLST (double Price, SelectOptions option)
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.Price = Price;  
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList(Adapter.SelectByField(obj,"Price",option),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien ServiceCode duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectByServiceCode (PT_Service_ModelEntity obj)
        { 
            return Adapter.SelectByField(obj,"ServiceCode");
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien ServiceCode duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectByServiceCode (PT_Service_ModelEntity obj,SelectOptions option)
        { 
            return Adapter.SelectByField(obj,"ServiceCode",option);
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien ServiceCode duoc set trong object
        /// </summary>
        /// <returns>List<PT_Service_ModelEntity></returns>
        public List<PT_Service_ModelEntity> SelectByServiceCodeLST (PT_Service_ModelEntity obj)
        { 
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList(Adapter.SelectByField(obj,"ServiceCode"),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien ServiceCode duoc set trong object
        /// </summary>
        /// <returns>List<PT_Service_ModelEntity></returns>
        public List<PT_Service_ModelEntity> SelectByServiceCodeLST (PT_Service_ModelEntity obj,SelectOptions option)
        { 
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList( Adapter.SelectByField(obj,"ServiceCode",option),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien ServiceCode 
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectByServiceCode (string ServiceCode )
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.ServiceCode = ServiceCode;  
            return Adapter.SelectByField(obj,"ServiceCode");
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien ServiceCode duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public DataTable SelectByServiceCode (string ServiceCode, SelectOptions option)
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.ServiceCode = ServiceCode;  
            return Adapter.SelectByField(obj,"ServiceCode",option);
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien ServiceCode 
        /// </summary>
        /// <returns>DataTable</returns>
        public List<PT_Service_ModelEntity> SelectByServiceCodeLST (string ServiceCode )
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.ServiceCode = ServiceCode;  
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList(Adapter.SelectByField(obj,"ServiceCode"),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien ServiceCode duoc set trong object
        /// </summary>
        /// <returns>DataTable</returns>
        public List<PT_Service_ModelEntity> SelectByServiceCodeLST (string ServiceCode, SelectOptions option)
        { 
            PT_Service_ModelEntity obj = new PT_Service_ModelEntity();
            obj.ServiceCode = ServiceCode;  
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList(Adapter.SelectByField(obj,"ServiceCode",option),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien duoc set trong object
        /// </summary>
        /// <returns>List<PT_Service_ModelEntity></returns>
        public List<PT_Service_ModelEntity> SelectWithConditionLST (PT_Service_ModelEntity obj)
        { 
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList( Adapter.SelectWithCondition(obj),new PT_Service_ModelEntity());
        }

        /// <summary>
        /// Lay du lieu theo cac dieu kien duoc set trong object
        /// </summary>
        /// <returns>List<PT_Service_ModelEntity></returns>
        public List<PT_Service_ModelEntity> SelectWithConditionLST (PT_Service_ModelEntity obj,SelectOptions option)
        { 
            return  (List<PT_Service_ModelEntity>) EntityUtil.CopyDataTableToEntityList( Adapter.SelectWithCondition(obj,option),new PT_Service_ModelEntity());
        }

}
}
